package com.sh.doctors.cloud.patient.model.repository

import com.sh.doctors.cloud.patient.model.local.dao.AriticleDao
import com.sh.doctors.cloud.patient.model.remote.AriticleService

/**
 * 远程访问成功后执行插入
 */
class AriticleRepo constructor(private val remote:AriticleService, private val local:AriticleDao){
    fun getAriticle() = remote.getAriticle().doOnSuccess{local.insetAll(it.data.news_list)}
}
